using System.Collections;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;

public class Move : MonoBehaviour
{
    // Start is called before the first frame update
    public float speed = 5f;
    public Vector3 movedir;
    void Start()
    {
        
    }

    // Update is called once per frame
    void Update()
    {
        float vertical = Input.GetAxis("Vertical");
        float horizontal = Input.GetAxis("Horizontal");
        movedir = (vertical * Vector3.up + horizontal * Vector3.right).normalized;
        transform.position += movedir * speed * Time.deltaTime;
    }
}
